import vue from 'vue'
import Vuex from 'vuex'

vue.use(Vuex)

const state = {
  article:'',
  userName:''
}

const actions = { }

const getters = { }

const mutations = {
  eidtArticle(state,val) {
    state.article = val;
    console.log(state.article)
  },
  userNameFun(state,val){
    state.userName = val
  } 
} 
 
export default new Vuex.Store({  
  state,
  actions,
  mutations,
  getters 
});  